﻿using System;
using System.Globalization;
using System.Windows.Data;
using System.Windows.Input;

namespace RytmSerca.Converters
{
    public class ProgressToCursorConverter : IValueConverter
    {
        private static readonly IValueConverter instance = new ProgressToCursorConverter();

        public static IValueConverter Instance
        {
            get { return instance; }
        }

        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            return ((bool) value)
                       ? Cursors.AppStarting
                       : Cursors.Arrow;

            
        }

        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
        {
            throw new NotImplementedException();
        }
    }
}